package com.time.company.db.model;

import com.time.company.servermodel.dynamics.Dynamics;
import com.time.company.servermodel.dynamics.Pic;

import org.litepal.crud.DataSupport;
import org.parceler.Parcel;

import java.util.List;

/**
 * Created by Bing on 2017/10/26.
 * E-mail is tx16bing@163.com
 */

@Parcel(Parcel.Serialization.BEAN)
public class DynamicsModel extends DataSupport {

    private String userId;
    private String logoUrl;
    private String userName;

    private String createAt;
    private String content;
    private String dynamicsId;
    private String likeNum;
    private String likeState;
    private String latitude;
    private String location;
    private String longitude;
    private String commentNum;
    private String shareUrl;

    private List<Pic> picList;

    public DynamicsModel() {
    }

    public DynamicsModel(Dynamics bean) {
        Dynamics.UserInfoBean userInfo = bean.getUserInfo();
        this.logoUrl = userInfo.getLogoUrl();
        this.userName = userInfo.getName();

        this.userId = bean.getUserId();
        this.createAt = bean.getCreateAt();
        this.content = bean.getContent();
        this.dynamicsId = bean.getId();
        this.likeNum = bean.getLikeNum();
        this.likeState = bean.getLikeState();
        this.latitude = bean.getLatitude();
        this.longitude = bean.getLongtitude();
        this.location = bean.getLocation();
        this.commentNum = bean.getCommentNum();
        this.shareUrl = bean.getShareUrl();

        this.picList = bean.getPicList();
    }


    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    public String getLogoUrl() {
        return logoUrl;
    }

    public void setLogoUrl(String logoUrl) {
        this.logoUrl = logoUrl;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getCreateAt() {
        return createAt;
    }

    public void setCreateAt(String createAt) {
        this.createAt = createAt;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getDynamicsId() {
        return dynamicsId;
    }

    public void setDynamicsId(String dynamicsId) {
        this.dynamicsId = dynamicsId;
    }

    public String getLikeNum() {
        return likeNum;
    }

    public void setLikeNum(String likeNum) {
        this.likeNum = likeNum;
    }

    public String getLikeState() {
        return likeState;
    }

    public void setLikeState(String likeState) {
        this.likeState = likeState;
    }

    public String getLatitude() {
        return latitude;
    }

    public void setLatitude(String latitude) {
        this.latitude = latitude;
    }

    public String getLocation() {
        return location;
    }

    public void setLocation(String location) {
        this.location = location;
    }

    public String getLongitude() {
        return longitude;
    }

    public void setLongitude(String longitude) {
        this.longitude = longitude;
    }

    public String getCommentNum() {
        return commentNum;
    }

    public void setCommentNum(String commentNum) {
        this.commentNum = commentNum;
    }

    public String getShareUrl() {
        return shareUrl;
    }

    public void setShareUrl(String shareUrl) {
        this.shareUrl = shareUrl;
    }

    public List<Pic> getPicList() {
        return picList;
    }

    public void setPicList(List<Pic> picList) {
        this.picList = picList;
    }
}
